<!DOCTYPE html>
<html lang="en-US">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>gen_binocular_proj_rectification [HALCON算子参考手册]</title>
<style type="text/css">
      body {
    color: #000000;
    background-color: #ffffff;
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
}

.body_main {
    margin-left: 35px;
    margin-right: 35px;
}

@media screen and (min-width:992px) {

    .body_main {
        margin-left: 10%;
        margin-right: 10%;
    }

    table.toctable {
        width: 80%
    }
}

@media screen and (min-width:1400px) {

    .body_main {
        margin-left: 15%;
        margin-right: 15%;
    }

    table.toctable {
        width: 70%
    }
}

body>div ul ul {
    margin-left: inherit;
}

a:link {
    color: #0044cc;
}

a:link,
a:visited {
    text-decoration: none;
}

a:link:hover,
a:visited:hover {
    text-decoration: underline;
}

th {
    text-align: left;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    text-rendering: optimizeLegibility;
    color: #666666;
}

code {
    font-family: monospace,monospace;
}

h1 a.halconoperator {
    font-family: Arial, Helvetica, sans-serif;
    color: #666666;
}

h2 a.halconoperator {
    font-family: Arial, Helvetica, sans-serif;
    color: #666666;
}

hr {
    border: 0;
    border-top: solid 1px #f28d26;
}

.pre {
    display: block;
    padding-bottom: 1ex;
    font-family: monospace;
    white-space: pre;
}

pre {
    font-family: monospace, monospace;
    padding: 1ex;
    white-space: pre-wrap;
}

.toc {
    font-size: 80%;
    border-top: 1px dashed #f28d26;
    border-bottom: 1px dashed #f28d26;
    padding-top: 5px;
    padding-bottom: 5px;
}

.inv {
    margin: 0;
    border: 0;
    padding: 0;
}

.banner {
    color: #666666;
    padding-left: 1em;
}

.logo {
    background-color: white;
}

.keyboard {
    font-size: 80%;
    padding-left: 3px;
    padding-right: 3px;
    border-radius: 5px;
    border-width: 1px;
    border-style: solid;
    border-color: #f28d26;
    background-color: #f3f3f3;
}

.warning {
    margin-top: 2ex;
    margin-bottom: 1ex;
    padding: 10px;
    text-align: center;
    border: 1px solid;
    color: #bb0000;
    background-color: #fff7f7
}

.imprint {
    margin-top: 1ex;
    font-size: 80%;
    color: #666666;
}

.imprinthead {
    font-weight: bolder;
    color: #666666;
}

.indexlink {
    text-align: right;
    padding-bottom: 5px;
}

.postscript {
    margin-top: 2ex;
    font-size: 80%;
    color: #666666
}

.evenrow {
    background-color: #e7e7ef;
    vertical-align: top;
}

.oddrow {
    background-color: #f7f7ff;
    vertical-align: top;
}

.headrow {
    background-color: #97979f;
    color: #ffffff;
    vertical-align: top;
}

.logorow {
    vertical-align: top;
}

.error {
    color: red;
}

.var {
    font-style: italic
}

.halconoperator {
    font-family: monospace, monospace;
}

span.operator {
    font-family: monospace, monospace;
}

span.procedure {
    font-family: monospace, monospace;
}

span.operation {
    font-family: monospace, monospace;
}

span.feature {
    font-family: Arial, Helvetica, Homerton, sans-serif;
}

ul {
    padding-left: 1.2em;
}

li.dot {
    list-style-type: square;
    color: #f28d26;
}

.breadcrumb {
    font-size: 80%;
    color: white;
    background-color: #062d64;
    margin-bottom: 20px;
    padding-left: 35px;
    padding-right: 35px;
    padding-bottom: 15px;
}

.webbar {
    font-size: 80%;
    background-color: #dddddd;
    margin-top: 0px;
    margin-left: -35px;
    margin-right: -35px;
    margin-bottom: 0px;
    padding-top: 5px;
    padding-left: 35px;
    padding-right: 35px;
    padding-bottom: 5px;
}

.footer {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    border-top: 1px dashed #f28d26;
    font-size: 80%;
    color: #666666;
    padding-bottom: 8px;
}

.footer .socialmedia a {
    padding-left: 7px;
}

.socialmedia {
    padding-top: 10px;
}

.copyright {
    margin-top: 19px;
}

.breadcrumb a {
    color: #ffffff;
    border-bottom: 1px solid white;
}

.breadcrumb a:link:hover,
.breadcrumb a:visited:hover {
    text-decoration: none;
    border-bottom: none;
}

.heading {
    margin-top: 1ex;
    font-size: 110%;
    font-weight: bold;
    color: #666666;
}

.text {
    color: black;
}

.example {
    font-size: 80%;
    background-color: #f3f3f3;
    border: 1px dashed #666666;
    padding: 10px;
}

.displaymath {
    display: block;
    text-align: center;
    margin-top: 1ex;
    margin-bottom: 1ex;
}

.title {
    float: left;
    padding-top: 3px;
    padding-bottom: 3px;
}

.signnote {
    font-family: Arial, Helvetica, Homerton, sans-serif;
    font-size: 80%;
    color: #666666;
    font-weight: lighter;
    font-style: italic
}

.par {
    margin-bottom: 1.5em;
}

.parhead {
    text-align: right;
}

.parname {
    float: left;
}

.pardesc {
    font-size: 85%;
    margin-top: 0.5em;
    margin-bottom: 0.5em;
    margin-left: 2em;
}

.parcat {
    color: #666;
    font-weight: bold;
}

*[data-if=cpp],
*[data-if=c],
*[data-if=dotnet],
*[data-if=com],
*[data-if=python] {
    display: none;
}

.tabbar {
    text-align: right;
    border-bottom: 1px solid #f28d26;
    margin-bottom: 0.5em;
}

ul.tabs {
    padding-top: 3px;
    padding-bottom: 3px;
    margin-top: 10px;
    margin-bottom: 0;
    font-size: 80%
}

ul.tabs li {
    padding-top: 3px;
    padding-bottom: 3px;
    display: inline;
    overflow: hidden;
    list-style-type: none;
    margin: 0;
    margin-left: 8px;
    border-top: 1px solid #666;
    border-left: 1px solid #666;
    border-right: 1px solid #666;
}

ul.tabs li.active {
    border-left: 1px solid #f28d26;
    border-right: 1px solid #f28d26;
    border-top: 1px solid #f28d26;
    border-bottom: 1px solid #fff;
}

ul.tabs li.inactive {
    background-color: #eee;
}

ul.tabs li a {
    padding-left: 5px;
    padding-right: 5px;
    color: #666;
}

ul.tabs li a:link:hover {
    text-decoration: none;
}

ul.tabs li.inactive a {
    color: #666;
}

ul.tabs li.active a {
    color: black;
}

dl.generic dd {
    margin-bottom: 1em;
}

.pari {
    color: olive;
}

.paro {
    color: maroon;
}

.comment {
    font-size: 80%;
    color: green;
    white-space: nowrap;
}

table.grid {
    border-collapse: collapse;
}

table.grid td {
    padding: 5px;
    border: 1px solid;
}

table.layout {
    border: 0px;
}

table.layout td {
    padding: 5px;
}

table.table {
    border-collapse: collapse;
}

table.table td {
    padding: 5px;
    border-left: 0px;
    border-right: 0px;
}

table.table tr:last-child {
    border-bottom: 1px solid;
}

table.table th {
    padding: 5px;
    border-top: 1px solid;
    border-bottom: 1px solid;
    border-left: 0px;
    border-right: 0px;
}

.details_summary {
    cursor: pointer;
}

table.toctable {
    width: 100%;
}

table.toctable col:first-child {
    width: 20%;
}

table.toctable col:nth-last-child(2) {
    width: 8%;
}

table.altcolored tr:nth-child(even) {
    background-color: #f3f3f3;
}

    </style>
<!--OP_REF_STYLE_END-->
<script>
    <!--
var active_lang='hdevelop';function switchVisibility(obj,active_lang,new_lang)
{var display_style='inline';
for(var i=0;i<obj.length;i++)
{if(obj.item(i).getAttribute('data-if')==new_lang)
{obj.item(i).style.display=display_style;}
if(obj.item(i).getAttribute('data-if')==active_lang)
{obj.item(i).style.display='none';}}
return;}
function toggleLanguage(new_lang,initial)
{if(active_lang!=new_lang)
{var lis=document.getElementsByTagName('li');for(var i=0;i<lis.length;i++)
{if(lis.item(i).id=='syn-'+new_lang)
{lis.item(i).className='active';}
else
{lis.item(i).className='inactive';}}
var divs=document.getElementsByTagName('div');var spans=document.getElementsByTagName('span');switchVisibility(divs,active_lang,new_lang);switchVisibility(spans,active_lang,new_lang);if(!initial)
{setCookie("halcon_reference_language",new_lang,null,null);}
active_lang=new_lang;}
return;}
function setCookie(name,value,domain,exp_offset,path,secure)
{localStorage.setItem(name,value);}
function getCookie(name)
{return localStorage.getItem(name);}
function initialize()
{var qs=location.href.split('?')[1];var qs_lang_raw=location.href.split('interface=')[1];var qs_lang;if(qs_lang_raw)
{qs_lang=qs_lang_raw.split('#')[0];}
var cookie_lang=getCookie("halcon_reference_language");var new_lang;if((qs_lang=="hdevelop")||(qs_lang=="dotnet")||(qs_lang=="python")||(qs_lang=="cpp")||(qs_lang=="c"))
{new_lang=qs_lang;setCookie("halcon_reference_language",new_lang,null,null);}
else if((cookie_lang=="hdevelop")||(cookie_lang=="dotnet")||(cookie_lang=="python")||(cookie_lang=="cpp")||(cookie_lang=="c"))
{new_lang=cookie_lang;}
else
{new_lang="hdevelop";}
toggleLanguage(new_lang,1);return;}
-->

  </script>
</head>
<body onload="initialize();">
<div class="breadcrumb">
<br class="inv"><a href="index.html">目录</a> / <a href="toc_3dreconstruction.html">3D Reconstruction</a> / <a href="toc_3dreconstruction_binocularstereo.html">Binocular Stereo</a><br class="inv">
</div>
<div class="body_main">
<div class="tabbar"><ul class="tabs">
<li id="syn-hdevelop" class="active"><a href="javascript:void(0);" onclick="toggleLanguage('hdevelop')" onfocus="blur()">HDevelop</a></li>
<li id="syn-dotnet" class="inactive"><a href="javascript:void(0);" onclick="toggleLanguage('dotnet')" onfocus="blur()">.NET</a></li>
<li id="syn-python" class="inactive"><a href="javascript:void(0);" onclick="toggleLanguage('python')" onfocus="blur()">Python</a></li>
<li id="syn-cpp" class="inactive"><a href="javascript:void(0);" onclick="toggleLanguage('cpp')" onfocus="blur()">C++</a></li>
<li id="syn-c" class="inactive"><a href="javascript:void(0);" onclick="toggleLanguage('c')" onfocus="blur()">C</a></li>
</ul></div>
<div class="indexlink">
<a href="index_classes.html"><span data-if="dotnet" style="display:none;">类别</span><span data-if="cpp" style="display:none;">类别</span></a><span data-if="dotnet" style="display:none;"> | </span><span data-if="cpp" style="display:none;"> | </span><a href="index_by_name.html">算子列表</a>
</div>
<!--OP_REF_HEADER_END-->
<h1 id="sec_name">
<span data-if="hdevelop" style="display:inline;">gen_binocular_proj_rectification</span><span data-if="c" style="display:none;">T_gen_binocular_proj_rectification</span><span data-if="cpp" style="display:none;">GenBinocularProjRectification</span><span data-if="dotnet" style="display:none;">GenBinocularProjRectification</span><span data-if="python" style="display:none;">gen_binocular_proj_rectification</span> (算子名称)</h1>
<h2>名称</h2>
<p><code><span data-if="hdevelop" style="display:inline;">gen_binocular_proj_rectification</span><span data-if="c" style="display:none;">T_gen_binocular_proj_rectification</span><span data-if="cpp" style="display:none;">GenBinocularProjRectification</span><span data-if="dotnet" style="display:none;">GenBinocularProjRectification</span><span data-if="python" style="display:none;">gen_binocular_proj_rectification</span></code> — Compute the projective rectification of weakly calibrated binocular
stereo images.</p>
<h2 id="sec_synopsis">参数签名</h2>
<div data-if="hdevelop" style="display:inline;">
<p>
<code><b>gen_binocular_proj_rectification</b>( : <a href="#Map1"><i>Map1</i></a>, <a href="#Map2"><i>Map2</i></a> : <a href="#FMatrix"><i>FMatrix</i></a>, <a href="#CovFMat"><i>CovFMat</i></a>, <a href="#Width1"><i>Width1</i></a>, <a href="#Height1"><i>Height1</i></a>, <a href="#Width2"><i>Width2</i></a>, <a href="#Height2"><i>Height2</i></a>, <a href="#SubSampling"><i>SubSampling</i></a>, <a href="#Mapping"><i>Mapping</i></a> : <a href="#CovFMatRect"><i>CovFMatRect</i></a>, <a href="#H1"><i>H1</i></a>, <a href="#H2"><i>H2</i></a>)</code></p>
</div>
<div data-if="c" style="display:none;">
<p>
<code>Herror <b>T_gen_binocular_proj_rectification</b>(Hobject* <a href="#Map1"><i>Map1</i></a>, Hobject* <a href="#Map2"><i>Map2</i></a>, const Htuple <a href="#FMatrix"><i>FMatrix</i></a>, const Htuple <a href="#CovFMat"><i>CovFMat</i></a>, const Htuple <a href="#Width1"><i>Width1</i></a>, const Htuple <a href="#Height1"><i>Height1</i></a>, const Htuple <a href="#Width2"><i>Width2</i></a>, const Htuple <a href="#Height2"><i>Height2</i></a>, const Htuple <a href="#SubSampling"><i>SubSampling</i></a>, const Htuple <a href="#Mapping"><i>Mapping</i></a>, Htuple* <a href="#CovFMatRect"><i>CovFMatRect</i></a>, Htuple* <a href="#H1"><i>H1</i></a>, Htuple* <a href="#H2"><i>H2</i></a>)</code></p>
</div>
<div data-if="cpp" style="display:none;">
<p>
<code>void <b>GenBinocularProjRectification</b>(HObject* <a href="#Map1"><i>Map1</i></a>, HObject* <a href="#Map2"><i>Map2</i></a>, const HTuple&amp; <a href="#FMatrix"><i>FMatrix</i></a>, const HTuple&amp; <a href="#CovFMat"><i>CovFMat</i></a>, const HTuple&amp; <a href="#Width1"><i>Width1</i></a>, const HTuple&amp; <a href="#Height1"><i>Height1</i></a>, const HTuple&amp; <a href="#Width2"><i>Width2</i></a>, const HTuple&amp; <a href="#Height2"><i>Height2</i></a>, const HTuple&amp; <a href="#SubSampling"><i>SubSampling</i></a>, const HTuple&amp; <a href="#Mapping"><i>Mapping</i></a>, HTuple* <a href="#CovFMatRect"><i>CovFMatRect</i></a>, HTuple* <a href="#H1"><i>H1</i></a>, HTuple* <a href="#H2"><i>H2</i></a>)</code></p>
<p>
<code><a href="HImage.html">HImage</a> <a href="HImage.html">HImage</a>::<b>GenBinocularProjRectification</b>(const HHomMat2D&amp; <a href="#FMatrix"><i>FMatrix</i></a>, const HTuple&amp; <a href="#CovFMat"><i>CovFMat</i></a>, Hlong <a href="#Width1"><i>Width1</i></a>, Hlong <a href="#Height1"><i>Height1</i></a>, Hlong <a href="#Width2"><i>Width2</i></a>, Hlong <a href="#Height2"><i>Height2</i></a>, const HTuple&amp; <a href="#SubSampling"><i>SubSampling</i></a>, const HString&amp; <a href="#Mapping"><i>Mapping</i></a>, HTuple* <a href="#CovFMatRect"><i>CovFMatRect</i></a>, HHomMat2D* <a href="#H1"><i>H1</i></a>, HHomMat2D* <a href="#H2"><i>H2</i></a>)</code></p>
<p>
<code><a href="HImage.html">HImage</a> <a href="HImage.html">HImage</a>::<b>GenBinocularProjRectification</b>(const HHomMat2D&amp; <a href="#FMatrix"><i>FMatrix</i></a>, const HTuple&amp; <a href="#CovFMat"><i>CovFMat</i></a>, Hlong <a href="#Width1"><i>Width1</i></a>, Hlong <a href="#Height1"><i>Height1</i></a>, Hlong <a href="#Width2"><i>Width2</i></a>, Hlong <a href="#Height2"><i>Height2</i></a>, Hlong <a href="#SubSampling"><i>SubSampling</i></a>, const HString&amp; <a href="#Mapping"><i>Mapping</i></a>, HTuple* <a href="#CovFMatRect"><i>CovFMatRect</i></a>, HHomMat2D* <a href="#H1"><i>H1</i></a>, HHomMat2D* <a href="#H2"><i>H2</i></a>)</code></p>
<p>
<code><a href="HImage.html">HImage</a> <a href="HImage.html">HImage</a>::<b>GenBinocularProjRectification</b>(const HHomMat2D&amp; <a href="#FMatrix"><i>FMatrix</i></a>, const HTuple&amp; <a href="#CovFMat"><i>CovFMat</i></a>, Hlong <a href="#Width1"><i>Width1</i></a>, Hlong <a href="#Height1"><i>Height1</i></a>, Hlong <a href="#Width2"><i>Width2</i></a>, Hlong <a href="#Height2"><i>Height2</i></a>, Hlong <a href="#SubSampling"><i>SubSampling</i></a>, const char* <a href="#Mapping"><i>Mapping</i></a>, HTuple* <a href="#CovFMatRect"><i>CovFMatRect</i></a>, HHomMat2D* <a href="#H1"><i>H1</i></a>, HHomMat2D* <a href="#H2"><i>H2</i></a>)</code></p>
<p>
<code><a href="HImage.html">HImage</a> <a href="HImage.html">HImage</a>::<b>GenBinocularProjRectification</b>(const HHomMat2D&amp; <a href="#FMatrix"><i>FMatrix</i></a>, const HTuple&amp; <a href="#CovFMat"><i>CovFMat</i></a>, Hlong <a href="#Width1"><i>Width1</i></a>, Hlong <a href="#Height1"><i>Height1</i></a>, Hlong <a href="#Width2"><i>Width2</i></a>, Hlong <a href="#Height2"><i>Height2</i></a>, Hlong <a href="#SubSampling"><i>SubSampling</i></a>, const wchar_t* <a href="#Mapping"><i>Mapping</i></a>, HTuple* <a href="#CovFMatRect"><i>CovFMatRect</i></a>, HHomMat2D* <a href="#H1"><i>H1</i></a>, HHomMat2D* <a href="#H2"><i>H2</i></a>)  <span class="signnote">
            (
            Windows only)
          </span></code></p>
<p>
<code><a href="HImage.html">HImage</a> <a href="HHomMat2D.html">HHomMat2D</a>::<b>GenBinocularProjRectification</b>(HImage* <a href="#Map2"><i>Map2</i></a>, const HTuple&amp; <a href="#CovFMat"><i>CovFMat</i></a>, Hlong <a href="#Width1"><i>Width1</i></a>, Hlong <a href="#Height1"><i>Height1</i></a>, Hlong <a href="#Width2"><i>Width2</i></a>, Hlong <a href="#Height2"><i>Height2</i></a>, const HTuple&amp; <a href="#SubSampling"><i>SubSampling</i></a>, const HString&amp; <a href="#Mapping"><i>Mapping</i></a>, HTuple* <a href="#CovFMatRect"><i>CovFMatRect</i></a>, HHomMat2D* <a href="#H1"><i>H1</i></a>, HHomMat2D* <a href="#H2"><i>H2</i></a>) const</code></p>
<p>
<code><a href="HImage.html">HImage</a> <a href="HHomMat2D.html">HHomMat2D</a>::<b>GenBinocularProjRectification</b>(HImage* <a href="#Map2"><i>Map2</i></a>, const HTuple&amp; <a href="#CovFMat"><i>CovFMat</i></a>, Hlong <a href="#Width1"><i>Width1</i></a>, Hlong <a href="#Height1"><i>Height1</i></a>, Hlong <a href="#Width2"><i>Width2</i></a>, Hlong <a href="#Height2"><i>Height2</i></a>, Hlong <a href="#SubSampling"><i>SubSampling</i></a>, const HString&amp; <a href="#Mapping"><i>Mapping</i></a>, HTuple* <a href="#CovFMatRect"><i>CovFMatRect</i></a>, HHomMat2D* <a href="#H1"><i>H1</i></a>, HHomMat2D* <a href="#H2"><i>H2</i></a>) const</code></p>
<p>
<code><a href="HImage.html">HImage</a> <a href="HHomMat2D.html">HHomMat2D</a>::<b>GenBinocularProjRectification</b>(HImage* <a href="#Map2"><i>Map2</i></a>, const HTuple&amp; <a href="#CovFMat"><i>CovFMat</i></a>, Hlong <a href="#Width1"><i>Width1</i></a>, Hlong <a href="#Height1"><i>Height1</i></a>, Hlong <a href="#Width2"><i>Width2</i></a>, Hlong <a href="#Height2"><i>Height2</i></a>, Hlong <a href="#SubSampling"><i>SubSampling</i></a>, const char* <a href="#Mapping"><i>Mapping</i></a>, HTuple* <a href="#CovFMatRect"><i>CovFMatRect</i></a>, HHomMat2D* <a href="#H1"><i>H1</i></a>, HHomMat2D* <a href="#H2"><i>H2</i></a>) const</code></p>
<p>
<code><a href="HImage.html">HImage</a> <a href="HHomMat2D.html">HHomMat2D</a>::<b>GenBinocularProjRectification</b>(HImage* <a href="#Map2"><i>Map2</i></a>, const HTuple&amp; <a href="#CovFMat"><i>CovFMat</i></a>, Hlong <a href="#Width1"><i>Width1</i></a>, Hlong <a href="#Height1"><i>Height1</i></a>, Hlong <a href="#Width2"><i>Width2</i></a>, Hlong <a href="#Height2"><i>Height2</i></a>, Hlong <a href="#SubSampling"><i>SubSampling</i></a>, const wchar_t* <a href="#Mapping"><i>Mapping</i></a>, HTuple* <a href="#CovFMatRect"><i>CovFMatRect</i></a>, HHomMat2D* <a href="#H1"><i>H1</i></a>, HHomMat2D* <a href="#H2"><i>H2</i></a>) const  <span class="signnote">
            (
            Windows only)
          </span></code></p>
</div>
<div data-if="com" style="display:none;"></div>
<div data-if="dotnet" style="display:none;">
<p>
<code>static void <a href="HOperatorSet.html">HOperatorSet</a>.<b>GenBinocularProjRectification</b>(out <a href="HObject.html">HObject</a> <a href="#Map1"><i>map1</i></a>, out <a href="HObject.html">HObject</a> <a href="#Map2"><i>map2</i></a>, <a href="HTuple.html">HTuple</a> <a href="#FMatrix"><i>FMatrix</i></a>, <a href="HTuple.html">HTuple</a> <a href="#CovFMat"><i>covFMat</i></a>, <a href="HTuple.html">HTuple</a> <a href="#Width1"><i>width1</i></a>, <a href="HTuple.html">HTuple</a> <a href="#Height1"><i>height1</i></a>, <a href="HTuple.html">HTuple</a> <a href="#Width2"><i>width2</i></a>, <a href="HTuple.html">HTuple</a> <a href="#Height2"><i>height2</i></a>, <a href="HTuple.html">HTuple</a> <a href="#SubSampling"><i>subSampling</i></a>, <a href="HTuple.html">HTuple</a> <a href="#Mapping"><i>mapping</i></a>, out <a href="HTuple.html">HTuple</a> <a href="#CovFMatRect"><i>covFMatRect</i></a>, out <a href="HTuple.html">HTuple</a> <a href="#H1"><i>h1</i></a>, out <a href="HTuple.html">HTuple</a> <a href="#H2"><i>h2</i></a>)</code></p>
<p>
<code><a href="HImage.html">HImage</a> <a href="HImage.html">HImage</a>.<b>GenBinocularProjRectification</b>(<a href="HHomMat2D.html">HHomMat2D</a> <a href="#FMatrix"><i>FMatrix</i></a>, <a href="HTuple.html">HTuple</a> <a href="#CovFMat"><i>covFMat</i></a>, int <a href="#Width1"><i>width1</i></a>, int <a href="#Height1"><i>height1</i></a>, int <a href="#Width2"><i>width2</i></a>, int <a href="#Height2"><i>height2</i></a>, <a href="HTuple.html">HTuple</a> <a href="#SubSampling"><i>subSampling</i></a>, string <a href="#Mapping"><i>mapping</i></a>, out <a href="HTuple.html">HTuple</a> <a href="#CovFMatRect"><i>covFMatRect</i></a>, out <a href="HHomMat2D.html">HHomMat2D</a> <a href="#H1"><i>h1</i></a>, out <a href="HHomMat2D.html">HHomMat2D</a> <a href="#H2"><i>h2</i></a>)</code></p>
<p>
<code><a href="HImage.html">HImage</a> <a href="HImage.html">HImage</a>.<b>GenBinocularProjRectification</b>(<a href="HHomMat2D.html">HHomMat2D</a> <a href="#FMatrix"><i>FMatrix</i></a>, <a href="HTuple.html">HTuple</a> <a href="#CovFMat"><i>covFMat</i></a>, int <a href="#Width1"><i>width1</i></a>, int <a href="#Height1"><i>height1</i></a>, int <a href="#Width2"><i>width2</i></a>, int <a href="#Height2"><i>height2</i></a>, int <a href="#SubSampling"><i>subSampling</i></a>, string <a href="#Mapping"><i>mapping</i></a>, out <a href="HTuple.html">HTuple</a> <a href="#CovFMatRect"><i>covFMatRect</i></a>, out <a href="HHomMat2D.html">HHomMat2D</a> <a href="#H1"><i>h1</i></a>, out <a href="HHomMat2D.html">HHomMat2D</a> <a href="#H2"><i>h2</i></a>)</code></p>
<p>
<code><a href="HImage.html">HImage</a> <a href="HHomMat2D.html">HHomMat2D</a>.<b>GenBinocularProjRectification</b>(out <a href="HImage.html">HImage</a> <a href="#Map2"><i>map2</i></a>, <a href="HTuple.html">HTuple</a> <a href="#CovFMat"><i>covFMat</i></a>, int <a href="#Width1"><i>width1</i></a>, int <a href="#Height1"><i>height1</i></a>, int <a href="#Width2"><i>width2</i></a>, int <a href="#Height2"><i>height2</i></a>, <a href="HTuple.html">HTuple</a> <a href="#SubSampling"><i>subSampling</i></a>, string <a href="#Mapping"><i>mapping</i></a>, out <a href="HTuple.html">HTuple</a> <a href="#CovFMatRect"><i>covFMatRect</i></a>, out <a href="HHomMat2D.html">HHomMat2D</a> <a href="#H1"><i>h1</i></a>, out <a href="HHomMat2D.html">HHomMat2D</a> <a href="#H2"><i>h2</i></a>)</code></p>
<p>
<code><a href="HImage.html">HImage</a> <a href="HHomMat2D.html">HHomMat2D</a>.<b>GenBinocularProjRectification</b>(out <a href="HImage.html">HImage</a> <a href="#Map2"><i>map2</i></a>, <a href="HTuple.html">HTuple</a> <a href="#CovFMat"><i>covFMat</i></a>, int <a href="#Width1"><i>width1</i></a>, int <a href="#Height1"><i>height1</i></a>, int <a href="#Width2"><i>width2</i></a>, int <a href="#Height2"><i>height2</i></a>, int <a href="#SubSampling"><i>subSampling</i></a>, string <a href="#Mapping"><i>mapping</i></a>, out <a href="HTuple.html">HTuple</a> <a href="#CovFMatRect"><i>covFMatRect</i></a>, out <a href="HHomMat2D.html">HHomMat2D</a> <a href="#H1"><i>h1</i></a>, out <a href="HHomMat2D.html">HHomMat2D</a> <a href="#H2"><i>h2</i></a>)</code></p>
</div>
<div data-if="python" style="display:none;">
<p>
<code>def <b>gen_binocular_proj_rectification</b>(<a href="#FMatrix"><i>fmatrix</i></a>: Sequence[Union[float, int]], <a href="#CovFMat"><i>cov_fmat</i></a>: Sequence[Union[float, int]], <a href="#Width1"><i>width_1</i></a>: int, <a href="#Height1"><i>height_1</i></a>: int, <a href="#Width2"><i>width_2</i></a>: int, <a href="#Height2"><i>height_2</i></a>: int, <a href="#SubSampling"><i>sub_sampling</i></a>: Union[int, float], <a href="#Mapping"><i>mapping</i></a>: str) -&gt; Tuple[HObject, HObject, Sequence[float], Sequence[float], Sequence[float]]</code></p>
</div>
<h2 id="sec_description">描述</h2>
<p>A binocular stereo setup is called weakly calibrated if the
fundamental matrix,
which describes the projective relation between the two images, is known.
Rectification is the process of finding a suitable set of transformations,
that transform both images such that all corresponding epipolar lines
become collinear and parallel to the horizontal axes.
The rectified images can be
thought of as acquired by a stereo configuration where the left and right
image plane are identical and the difference between both image centers is
a horizontal translation. Note that rectification can only be performed if
both of the epipoles are located outside the images.
</p>
<p>Typically, the fundamental matrix is calculated beforehand with
<a href="match_fundamental_matrix_ransac.html"><code><span data-if="hdevelop" style="display:inline">match_fundamental_matrix_ransac</span><span data-if="c" style="display:none">match_fundamental_matrix_ransac</span><span data-if="cpp" style="display:none">MatchFundamentalMatrixRansac</span><span data-if="com" style="display:none">MatchFundamentalMatrixRansac</span><span data-if="dotnet" style="display:none">MatchFundamentalMatrixRansac</span><span data-if="python" style="display:none">match_fundamental_matrix_ransac</span></code></a> and  <a href="#FMatrix"><i><code><span data-if="hdevelop" style="display:inline">FMatrix</span><span data-if="c" style="display:none">FMatrix</span><span data-if="cpp" style="display:none">FMatrix</span><span data-if="com" style="display:none">FMatrix</span><span data-if="dotnet" style="display:none">FMatrix</span><span data-if="python" style="display:none">fmatrix</span></code></i></a> is the basis
for the computation of the two homographies <a href="#H1"><i><code><span data-if="hdevelop" style="display:inline">H1</span><span data-if="c" style="display:none">H1</span><span data-if="cpp" style="display:none">H1</span><span data-if="com" style="display:none">H1</span><span data-if="dotnet" style="display:none">h1</span><span data-if="python" style="display:none">h1</span></code></i></a> and <a href="#H2"><i><code><span data-if="hdevelop" style="display:inline">H2</span><span data-if="c" style="display:none">H2</span><span data-if="cpp" style="display:none">H2</span><span data-if="com" style="display:none">H2</span><span data-if="dotnet" style="display:none">h2</span><span data-if="python" style="display:none">h2</span></code></i></a>,
which describe the rectifications for the left image and the right image
respectively. Since a projective rectification is an underdetermined
problem,
additional constraints are defined: the algorithm chooses the set
of homographies that minimizes the projective distortion induced by the
homographies in both images. For the computation of this cost function the
dimensions of the images must be provided in <a href="#Width1"><i><code><span data-if="hdevelop" style="display:inline">Width1</span><span data-if="c" style="display:none">Width1</span><span data-if="cpp" style="display:none">Width1</span><span data-if="com" style="display:none">Width1</span><span data-if="dotnet" style="display:none">width1</span><span data-if="python" style="display:none">width_1</span></code></i></a>,
<a href="#Height1"><i><code><span data-if="hdevelop" style="display:inline">Height1</span><span data-if="c" style="display:none">Height1</span><span data-if="cpp" style="display:none">Height1</span><span data-if="com" style="display:none">Height1</span><span data-if="dotnet" style="display:none">height1</span><span data-if="python" style="display:none">height_1</span></code></i></a>, <a href="#Width2"><i><code><span data-if="hdevelop" style="display:inline">Width2</span><span data-if="c" style="display:none">Width2</span><span data-if="cpp" style="display:none">Width2</span><span data-if="com" style="display:none">Width2</span><span data-if="dotnet" style="display:none">width2</span><span data-if="python" style="display:none">width_2</span></code></i></a>, <a href="#Height2"><i><code><span data-if="hdevelop" style="display:inline">Height2</span><span data-if="c" style="display:none">Height2</span><span data-if="cpp" style="display:none">Height2</span><span data-if="com" style="display:none">Height2</span><span data-if="dotnet" style="display:none">height2</span><span data-if="python" style="display:none">height_2</span></code></i></a>. After rectification
the fundamental matrix is always of the canonical form
<span title="1" class="displaymath"><!-- Created by MetaPost 1.902 on 2023.05.15:2033 --><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" width="8.56561em" height="3.7116em" viewBox="0 0 137.049805 59.385666">
<!-- Original BoundingBox: -68.524902 -29.692825 68.524902 29.692841 -->
  <defs>
    <g transform="scale(0.009963,0.009963)" id="GLYPHcmr10_48">
      <path style="fill-rule: evenodd;" d="M460.000000 -320.000000C460.000000 -400.000000,455.000000 -480.000000,420.000000 -554.000000C374.000000 -650.000000,292.000000 -666.000000,250.000000 -666.000000C190.000000 -666.000000,117.000000 -640.000000,76.000000 -547.000000C44.000000 -478.000000,39.000000 -400.000000,39.000000 -320.000000C39.000000 -245.000000,43.000000 -155.000000,84.000000 -79.000000C127.000000 2.000000,200.000000 22.000000,249.000000 22.000000C303.000000 22.000000,379.000000 1.000000,423.000000 -94.000000C455.000000 -163.000000,460.000000 -241.000000,460.000000 -320.000000M249.000000 -0.000000C210.000000 -0.000000,151.000000 -25.000000,133.000000 -121.000000C122.000000 -181.000000,122.000000 -273.000000,122.000000 -332.000000C122.000000 -396.000000,122.000000 -462.000000,130.000000 -516.000000C149.000000 -635.000000,224.000000 -644.000000,249.000000 -644.000000C282.000000 -644.000000,348.000000 -626.000000,367.000000 -527.000000C377.000000 -471.000000,377.000000 -395.000000,377.000000 -332.000000C377.000000 -257.000000,377.000000 -189.000000,366.000000 -125.000000C351.000000 -30.000000,294.000000 -0.000000,249.000000 -0.000000"></path>
    </g>
    <g transform="scale(0.009963,0.009963)" id="GLYPHcmr10_49">
      <path style="fill-rule: evenodd;" d="M294.000000 -640.000000C294.000000 -664.000000,294.000000 -666.000000,271.000000 -666.000000C209.000000 -602.000000,121.000000 -602.000000,89.000000 -602.000000L89.000000 -571.000000C109.000000 -571.000000,168.000000 -571.000000,220.000000 -597.000000L220.000000 -79.000000C220.000000 -43.000000,217.000000 -31.000000,127.000000 -31.000000L95.000000 -31.000000L95.000000 -0.000000L257.000000 -0.000000L130.000000 -3.000000L217.000000 -3.000000L257.000000 -3.000000L297.000000 -3.000000L384.000000 -3.000000L419.000000 -0.000000L419.000000 -31.000000L387.000000 -31.000000C297.000000 -31.000000,294.000000 -42.000000,294.000000 -79.000000"></path>
    </g>
    <g transform="scale(0.009963,0.009963)" id="GLYPHcmsy10_0">
      <path style="fill-rule: evenodd;" d="M659.000000 -230.000000C676.000000 -230.000000,694.000000 -230.000000,694.000000 -250.000000C694.000000 -270.000000,676.000000 -270.000000,659.000000 -270.000000L118.000000 -270.000000C101.000000 -270.000000,83.000000 -270.000000,83.000000 -250.000000C83.000000 -230.000000,101.000000 -230.000000,118.000000 -230.000000"></path>
    </g>
    <g transform="scale(0.009963,0.009963)" id="GLYPHcmmi10_58">
      <path style="fill-rule: evenodd;" d="M192.000000 -53.000000C192.000000 -82.000000,168.000000 -106.000000,139.000000 -106.000000C110.000000 -106.000000,86.000000 -82.000000,86.000000 -53.000000C86.000000 -24.000000,110.000000 -0.000000,139.000000 -0.000000C168.000000 -0.000000,192.000000 -24.000000,192.000000 -53.000000"></path>
    </g>
    <g transform="scale(0.009963,0.009963)" id="GLYPHcmex10_48">
      <path style="fill-rule: evenodd;" d="M374.000000 1770.000000C396.000000 1770.000000,402.000000 1770.000000,402.000000 1756.000000C404.000000 1055.000000,485.000000 473.000000,835.000000 -16.000000C842.000000 -25.000000,842.000000 -27.000000,842.000000 -29.000000C842.000000 -39.000000,835.000000 -39.000000,819.000000 -39.000000C803.000000 -39.000000,801.000000 -39.000000,799.000000 -37.000000C795.000000 -34.000000,668.000000 112.000000,567.000000 313.000000C435.000000 577.000000,352.000000 880.000000,315.000000 1244.000000C312.000000 1275.000000,291.000000 1483.000000,291.000000 1720.000000L291.000000 1759.000000C292.000000 1770.000000,298.000000 1770.000000,319.000000 1770.000000"></path>
    </g>
    <g transform="scale(0.009963,0.009963)" id="GLYPHcmex10_49">
      <path style="fill-rule: evenodd;" d="M583.000000 1720.000000C583.000000 1109.000000,474.000000 751.000000,443.000000 650.000000C375.000000 428.000000,264.000000 194.000000,97.000000 -12.000000C82.000000 -30.000000,78.000000 -35.000000,74.000000 -37.000000C72.000000 -38.000000,71.000000 -39.000000,55.000000 -39.000000C40.000000 -39.000000,32.000000 -39.000000,32.000000 -29.000000C32.000000 -27.000000,32.000000 -25.000000,45.000000 -7.000000C393.000000 479.000000,471.000000 1079.000000,472.000000 1756.000000C472.000000 1770.000000,478.000000 1770.000000,500.000000 1770.000000L555.000000 1770.000000C576.000000 1770.000000,582.000000 1770.000000,583.000000 1759.000000"></path>
    </g>
    <g transform="scale(0.009963,0.009963)" id="GLYPHcmex10_64">
      <path style="fill-rule: evenodd;" d="M319.000000 -50.000000C298.000000 -50.000000,292.000000 -50.000000,291.000000 -39.000000L291.000000 -0.000000C291.000000 611.000000,400.000000 969.000000,431.000000 1070.000000C499.000000 1292.000000,610.000000 1526.000000,777.000000 1732.000000C792.000000 1750.000000,796.000000 1755.000000,800.000000 1757.000000C802.000000 1758.000000,803.000000 1759.000000,819.000000 1759.000000C835.000000 1759.000000,842.000000 1759.000000,842.000000 1749.000000C842.000000 1747.000000,842.000000 1745.000000,836.000000 1736.000000C503.000000 1274.000000,403.000000 718.000000,402.000000 -36.000000C402.000000 -50.000000,396.000000 -50.000000,374.000000 -50.000000"></path>
    </g>
    <g transform="scale(0.009963,0.009963)" id="GLYPHcmex10_65">
      <path style="fill-rule: evenodd;" d="M583.000000 -39.000000C582.000000 -50.000000,576.000000 -50.000000,555.000000 -50.000000L500.000000 -50.000000C478.000000 -50.000000,472.000000 -50.000000,472.000000 -36.000000C472.000000 67.000000,471.000000 305.000000,445.000000 554.000000C391.000000 1071.000000,258.000000 1429.000000,39.000000 1736.000000C32.000000 1745.000000,32.000000 1747.000000,32.000000 1749.000000C32.000000 1759.000000,40.000000 1759.000000,55.000000 1759.000000C71.000000 1759.000000,73.000000 1759.000000,75.000000 1757.000000C79.000000 1754.000000,206.000000 1608.000000,307.000000 1407.000000C439.000000 1143.000000,522.000000 840.000000,559.000000 476.000000C562.000000 445.000000,583.000000 237.000000,583.000000 -0.000000"></path>
    </g>
  </defs>
  <g transform="matrix(1.600006,-0.000000,-0.000000,1.600006,0.475098 0.944763)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
    <use xlink:href="#GLYPHcmex10_48"></use>
  </g>
  <g transform="matrix(1.600006,-0.000000,-0.000000,1.600006,0.475098 29.637527)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
    <use xlink:href="#GLYPHcmex10_64"></use>
  </g>
  <g transform="matrix(1.600006,-0.000000,-0.000000,1.600006,22.392929 13.697296)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
    <use xlink:href="#GLYPHcmr10_48"></use>
  </g>
  <g transform="matrix(1.600006,-0.000000,-0.000000,1.600006,46.303421 13.697296)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
    <use xlink:href="#GLYPHcmr10_48"></use>
  </g>
  <g transform="matrix(1.600006,-0.000000,-0.000000,1.600006,76.412979 13.697296)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
    <use xlink:href="#GLYPHcmr10_48"></use>
  </g>
  <g transform="matrix(1.600006,-0.000000,-0.000000,1.600006,22.392929 32.825531)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
    <use xlink:href="#GLYPHcmr10_48"></use>
  </g>
  <g transform="matrix(1.600006,-0.000000,-0.000000,1.600006,46.303421 32.825531)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
    <use xlink:href="#GLYPHcmr10_48"></use>
  </g>
  <g transform="matrix(1.600006,-0.000000,-0.000000,1.600006,70.213913 32.825531)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
    <use xlink:href="#GLYPHcmsy10_0"></use>
  </g>
  <g transform="matrix(1.600006,-0.000000,-0.000000,1.600006,82.611893 32.825531)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
    <use xlink:href="#GLYPHcmr10_49"></use>
  </g>
  <g transform="matrix(1.600006,-0.000000,-0.000000,1.600006,22.392929 51.953918)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
    <use xlink:href="#GLYPHcmr10_48"></use>
  </g>
  <g transform="matrix(1.600006,-0.000000,-0.000000,1.600006,46.303421 51.953918)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
    <use xlink:href="#GLYPHcmr10_49"></use>
  </g>
  <g transform="matrix(1.600006,-0.000000,-0.000000,1.600006,76.412979 51.953918)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
    <use xlink:href="#GLYPHcmr10_48"></use>
  </g>
  <g transform="matrix(1.600006,-0.000000,-0.000000,1.600006,98.552277 0.944763)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
    <use xlink:href="#GLYPHcmex10_49"></use>
  </g>
  <g transform="matrix(1.600006,-0.000000,-0.000000,1.600006,98.552277 29.637527)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
    <use xlink:href="#GLYPHcmex10_65"></use>
  </g>
  <g transform="matrix(1.600006,-0.000000,-0.000000,1.600006,131.097031 32.985046)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
    <use xlink:href="#GLYPHcmmi10_58"></use>
  </g>
</svg></span>
</p>
<p>In the case of a known covariance matrix  <a href="#CovFMat"><i><code><span data-if="hdevelop" style="display:inline">CovFMat</span><span data-if="c" style="display:none">CovFMat</span><span data-if="cpp" style="display:none">CovFMat</span><span data-if="com" style="display:none">CovFMat</span><span data-if="dotnet" style="display:none">covFMat</span><span data-if="python" style="display:none">cov_fmat</span></code></i></a> of the
fundamental matrix <a href="#FMatrix"><i><code><span data-if="hdevelop" style="display:inline">FMatrix</span><span data-if="c" style="display:none">FMatrix</span><span data-if="cpp" style="display:none">FMatrix</span><span data-if="com" style="display:none">FMatrix</span><span data-if="dotnet" style="display:none">FMatrix</span><span data-if="python" style="display:none">fmatrix</span></code></i></a>, the covariance matrix
<a href="#CovFMatRect"><i><code><span data-if="hdevelop" style="display:inline">CovFMatRect</span><span data-if="c" style="display:none">CovFMatRect</span><span data-if="cpp" style="display:none">CovFMatRect</span><span data-if="com" style="display:none">CovFMatRect</span><span data-if="dotnet" style="display:none">covFMatRect</span><span data-if="python" style="display:none">cov_fmat_rect</span></code></i></a> of the
above rectified fundamental matrix is calculated. This can help for an
improved stereo matching process because the covariance matrix defines in
terms of probabilities the image domain where to find a corresponding match.
</p>
<p>Similar to 该算子 <a href="gen_binocular_rectification_map.html"><code><span data-if="hdevelop" style="display:inline">gen_binocular_rectification_map</span><span data-if="c" style="display:none">gen_binocular_rectification_map</span><span data-if="cpp" style="display:none">GenBinocularRectificationMap</span><span data-if="com" style="display:none">GenBinocularRectificationMap</span><span data-if="dotnet" style="display:none">GenBinocularRectificationMap</span><span data-if="python" style="display:none">gen_binocular_rectification_map</span></code></a> the
output images <a href="#Map1"><i><code><span data-if="hdevelop" style="display:inline">Map1</span><span data-if="c" style="display:none">Map1</span><span data-if="cpp" style="display:none">Map1</span><span data-if="com" style="display:none">Map1</span><span data-if="dotnet" style="display:none">map1</span><span data-if="python" style="display:none">map_1</span></code></i></a> and <a href="#Map2"><i><code><span data-if="hdevelop" style="display:inline">Map2</span><span data-if="c" style="display:none">Map2</span><span data-if="cpp" style="display:none">Map2</span><span data-if="com" style="display:none">Map2</span><span data-if="dotnet" style="display:none">map2</span><span data-if="python" style="display:none">map_2</span></code></i></a> describe the transformation,
also called mapping, of the original images to the rectified ones.
The parameter <a href="#Mapping"><i><code><span data-if="hdevelop" style="display:inline">Mapping</span><span data-if="c" style="display:none">Mapping</span><span data-if="cpp" style="display:none">Mapping</span><span data-if="com" style="display:none">Mapping</span><span data-if="dotnet" style="display:none">mapping</span><span data-if="python" style="display:none">mapping</span></code></i></a> specifies whether bilinear interpolation
(<i><span data-if="hdevelop" style="display:inline">'bilinear_map'</span><span data-if="c" style="display:none">"bilinear_map"</span><span data-if="cpp" style="display:none">"bilinear_map"</span><span data-if="com" style="display:none">"bilinear_map"</span><span data-if="dotnet" style="display:none">"bilinear_map"</span><span data-if="python" style="display:none">"bilinear_map"</span></i>) should be applied between the pixels in the input
image or whether the gray value of the nearest neighboring pixel should be
taken (<i><span data-if="hdevelop" style="display:inline">'nn_map'</span><span data-if="c" style="display:none">"nn_map"</span><span data-if="cpp" style="display:none">"nn_map"</span><span data-if="com" style="display:none">"nn_map"</span><span data-if="dotnet" style="display:none">"nn_map"</span><span data-if="python" style="display:none">"nn_map"</span></i>).
The size and resolution of the maps and of the transformed
images can be adjusted by the parameter <a href="#SubSampling"><i><code><span data-if="hdevelop" style="display:inline">SubSampling</span><span data-if="c" style="display:none">SubSampling</span><span data-if="cpp" style="display:none">SubSampling</span><span data-if="com" style="display:none">SubSampling</span><span data-if="dotnet" style="display:none">subSampling</span><span data-if="python" style="display:none">sub_sampling</span></code></i></a>, which applies
a sub-sampling factor to the original images. For example, a factor of two
will halve the image sizes. If just the two homographies are required
<a href="#Mapping"><i><code><span data-if="hdevelop" style="display:inline">Mapping</span><span data-if="c" style="display:none">Mapping</span><span data-if="cpp" style="display:none">Mapping</span><span data-if="com" style="display:none">Mapping</span><span data-if="dotnet" style="display:none">mapping</span><span data-if="python" style="display:none">mapping</span></code></i></a> can be set to <i><span data-if="hdevelop" style="display:inline">'no_map'</span><span data-if="c" style="display:none">"no_map"</span><span data-if="cpp" style="display:none">"no_map"</span><span data-if="com" style="display:none">"no_map"</span><span data-if="dotnet" style="display:none">"no_map"</span><span data-if="python" style="display:none">"no_map"</span></i> and no maps will be
returned.
For speed reasons, this option should be used if for a
specific stereo configuration the images must be rectified only once.
If the stereo setup is fixed, the maps should be generated only once
and both images should be rectified with <a href="map_image.html"><code><span data-if="hdevelop" style="display:inline">map_image</span><span data-if="c" style="display:none">map_image</span><span data-if="cpp" style="display:none">MapImage</span><span data-if="com" style="display:none">MapImage</span><span data-if="dotnet" style="display:none">MapImage</span><span data-if="python" style="display:none">map_image</span></code></a>;
this will result in the smallest computational cost for on-line
rectification.
</p>When using the maps, the transformed images are of the same size as
their maps.
Each pixel in the map contains the description of how the new pixel at this
position is generated.
The images <a href="#Map1"><i><code><span data-if="hdevelop" style="display:inline">Map1</span><span data-if="c" style="display:none">Map1</span><span data-if="cpp" style="display:none">Map1</span><span data-if="com" style="display:none">Map1</span><span data-if="dotnet" style="display:none">map1</span><span data-if="python" style="display:none">map_1</span></code></i></a> and <a href="#Map2"><i><code><span data-if="hdevelop" style="display:inline">Map2</span><span data-if="c" style="display:none">Map2</span><span data-if="cpp" style="display:none">Map2</span><span data-if="com" style="display:none">Map2</span><span data-if="dotnet" style="display:none">map2</span><span data-if="python" style="display:none">map_2</span></code></i></a> are single channel images if
<a href="#Mapping"><i><code><span data-if="hdevelop" style="display:inline">Mapping</span><span data-if="c" style="display:none">Mapping</span><span data-if="cpp" style="display:none">Mapping</span><span data-if="com" style="display:none">Mapping</span><span data-if="dotnet" style="display:none">mapping</span><span data-if="python" style="display:none">mapping</span></code></i></a> is set to <i><span data-if="hdevelop" style="display:inline">'nn_map'</span><span data-if="c" style="display:none">"nn_map"</span><span data-if="cpp" style="display:none">"nn_map"</span><span data-if="com" style="display:none">"nn_map"</span><span data-if="dotnet" style="display:none">"nn_map"</span><span data-if="python" style="display:none">"nn_map"</span></i> and five channel images if
it is set to <i><span data-if="hdevelop" style="display:inline">'bilinear_map'</span><span data-if="c" style="display:none">"bilinear_map"</span><span data-if="cpp" style="display:none">"bilinear_map"</span><span data-if="com" style="display:none">"bilinear_map"</span><span data-if="dotnet" style="display:none">"bilinear_map"</span><span data-if="python" style="display:none">"bilinear_map"</span></i>. In the first channel, which is of type
int4, the pixels contain the linear coordinates of their reference pixels
in the original image. With <a href="#Mapping"><i><code><span data-if="hdevelop" style="display:inline">Mapping</span><span data-if="c" style="display:none">Mapping</span><span data-if="cpp" style="display:none">Mapping</span><span data-if="com" style="display:none">Mapping</span><span data-if="dotnet" style="display:none">mapping</span><span data-if="python" style="display:none">mapping</span></code></i></a> equal to <i><span data-if="hdevelop" style="display:inline">'no_map'</span><span data-if="c" style="display:none">"no_map"</span><span data-if="cpp" style="display:none">"no_map"</span><span data-if="com" style="display:none">"no_map"</span><span data-if="dotnet" style="display:none">"no_map"</span><span data-if="python" style="display:none">"no_map"</span></i>
this reference pixel is the nearest neighbor to the back-transformed pixel
coordinates of the map.
In the case of bilinear interpolation the reference pixel is the next upper
left pixel relative to the back-transformed coordinates.
The following scheme shows the ordering of the pixels in the original image
next to the back-transformed pixel coordinates, where the reference pixel
takes the number 2.

<div style="text-align:center"><table style="margin-left:auto;margin-right:auto" class="grid">
<col span="1">
<col span="1">
<tr>
<td style="text-align:center">
2 </td>
<td style="text-align:center"> 3 </td>
</tr>
<tr>
<td style="text-align:center">
4 </td>
<td style="text-align:center"> 5
</td>
</tr>
</table></div>

<p>The channels 2 to 5, which are of type uint2, contain
the weights of the relevant pixels for the bilinear interpolation.
</p>
<p>Based on the rectified images, the disparity be
computed using <a href="binocular_disparity.html"><code><span data-if="hdevelop" style="display:inline">binocular_disparity</span><span data-if="c" style="display:none">binocular_disparity</span><span data-if="cpp" style="display:none">BinocularDisparity</span><span data-if="com" style="display:none">BinocularDisparity</span><span data-if="dotnet" style="display:none">BinocularDisparity</span><span data-if="python" style="display:none">binocular_disparity</span></code></a>.
In contrast to stereo with fully calibrated cameras, using 该算子
<a href="gen_binocular_rectification_map.html"><code><span data-if="hdevelop" style="display:inline">gen_binocular_rectification_map</span><span data-if="c" style="display:none">gen_binocular_rectification_map</span><span data-if="cpp" style="display:none">GenBinocularRectificationMap</span><span data-if="com" style="display:none">GenBinocularRectificationMap</span><span data-if="dotnet" style="display:none">GenBinocularRectificationMap</span><span data-if="python" style="display:none">gen_binocular_rectification_map</span></code></a> and its successors, metric depth
information can not be derived for weakly calibrated cameras.
The disparity map gives just a qualitative depth ordering of the
scene.
</p>
<h2 id="sec_execution">运行信息</h2>
<ul>
  <li>多线程类型:可重入(与非独占操作符并行运行)。</li>
<li>多线程作用域:全局(可以从任何线程调用)。</li>
  <li>未经并行化处理。</li>
</ul>
<h2 id="sec_parameters">参数表</h2>
  <div class="par">
<div class="parhead">
<span id="Map1" class="parname"><b><code><span data-if="hdevelop" style="display:inline">Map1</span><span data-if="c" style="display:none">Map1</span><span data-if="cpp" style="display:none">Map1</span><span data-if="com" style="display:none">Map1</span><span data-if="dotnet" style="display:none">map1</span><span data-if="python" style="display:none">map_1</span></code></b> (output_object)  </span><span>image(-array) <code>→</code> <span data-if="hdevelop" style="display:inline">object</span><span data-if="dotnet" style="display:none"><a href="HImage.html">HImage</a></span><span data-if="python" style="display:none">HObject</span><span data-if="cpp" style="display:none"><a href="HImage.html">HImage</a></span><span data-if="c" style="display:none">Hobject *</span> (int4 / uint2)</span>
</div>
<p class="pardesc">Image coding the rectification of the 1. image.</p>
</div>
  <div class="par">
<div class="parhead">
<span id="Map2" class="parname"><b><code><span data-if="hdevelop" style="display:inline">Map2</span><span data-if="c" style="display:none">Map2</span><span data-if="cpp" style="display:none">Map2</span><span data-if="com" style="display:none">Map2</span><span data-if="dotnet" style="display:none">map2</span><span data-if="python" style="display:none">map_2</span></code></b> (output_object)  </span><span>image(-array) <code>→</code> <span data-if="hdevelop" style="display:inline">object</span><span data-if="dotnet" style="display:none"><a href="HImage.html">HImage</a></span><span data-if="python" style="display:none">HObject</span><span data-if="cpp" style="display:none"><a href="HImage.html">HImage</a></span><span data-if="c" style="display:none">Hobject *</span> (int4 / uint2)</span>
</div>
<p class="pardesc">Image coding the rectification of the 2. image.</p>
</div>
  <div class="par">
<div class="parhead">
<span id="FMatrix" class="parname"><b><code><span data-if="hdevelop" style="display:inline">FMatrix</span><span data-if="c" style="display:none">FMatrix</span><span data-if="cpp" style="display:none">FMatrix</span><span data-if="com" style="display:none">FMatrix</span><span data-if="dotnet" style="display:none">FMatrix</span><span data-if="python" style="display:none">fmatrix</span></code></b> (input_control)  </span><span>hom_mat2d <code>→</code> <span data-if="dotnet" style="display:none"><a href="HHomMat2D.html">HHomMat2D</a>, </span><span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">Sequence[Union[float, int]]</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (real / </span><span data-if="hdevelop" style="display:inline">integer)</span><span data-if="dotnet" style="display:none"> (<i>double</i> / </span><span data-if="dotnet" style="display:none">int / </span><span data-if="dotnet" style="display:none">long)</span><span data-if="cpp" style="display:none"> (<i>double</i> / </span><span data-if="cpp" style="display:none">Hlong)</span><span data-if="c" style="display:none"> (<i>double</i> / </span><span data-if="c" style="display:none">Hlong)</span></span>
</div>
<p class="pardesc">Fundamental matrix.</p>
</div>
  <div class="par">
<div class="parhead">
<span id="CovFMat" class="parname"><b><code><span data-if="hdevelop" style="display:inline">CovFMat</span><span data-if="c" style="display:none">CovFMat</span><span data-if="cpp" style="display:none">CovFMat</span><span data-if="com" style="display:none">CovFMat</span><span data-if="dotnet" style="display:none">covFMat</span><span data-if="python" style="display:none">cov_fmat</span></code></b> (input_control)  </span><span>number-array <code>→</code> <span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">Sequence[Union[float, int]]</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (real / </span><span data-if="hdevelop" style="display:inline">integer)</span><span data-if="dotnet" style="display:none"> (<i>double</i> / </span><span data-if="dotnet" style="display:none">int / </span><span data-if="dotnet" style="display:none">long)</span><span data-if="cpp" style="display:none"> (<i>double</i> / </span><span data-if="cpp" style="display:none">Hlong)</span><span data-if="c" style="display:none"> (<i>double</i> / </span><span data-if="c" style="display:none">Hlong)</span></span>
</div>
<p class="pardesc">9x9 covariance matrix of the
fundamental matrix.</p>
<p class="pardesc"><span class="parcat">Default:
      </span>[]</p>
</div>
  <div class="par">
<div class="parhead">
<span id="Width1" class="parname"><b><code><span data-if="hdevelop" style="display:inline">Width1</span><span data-if="c" style="display:none">Width1</span><span data-if="cpp" style="display:none">Width1</span><span data-if="com" style="display:none">Width1</span><span data-if="dotnet" style="display:none">width1</span><span data-if="python" style="display:none">width_1</span></code></b> (input_control)  </span><span>integer <code>→</code> <span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">int</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (integer)</span><span data-if="dotnet" style="display:none"> (<i>int</i> / </span><span data-if="dotnet" style="display:none">long)</span><span data-if="cpp" style="display:none"> (<i>Hlong</i>)</span><span data-if="c" style="display:none"> (<i>Hlong</i>)</span></span>
</div>
<p class="pardesc">Width of the 1. image.</p>
<p class="pardesc"><span class="parcat">Default:
      </span>512</p>
<p class="pardesc"><span class="parcat">Suggested values:
      </span>128, 256, 512, 1024</p>
<p class="pardesc"><span class="parcat">Restriction:
      </span><code>Width1 &gt; 0</code></p>
</div>
  <div class="par">
<div class="parhead">
<span id="Height1" class="parname"><b><code><span data-if="hdevelop" style="display:inline">Height1</span><span data-if="c" style="display:none">Height1</span><span data-if="cpp" style="display:none">Height1</span><span data-if="com" style="display:none">Height1</span><span data-if="dotnet" style="display:none">height1</span><span data-if="python" style="display:none">height_1</span></code></b> (input_control)  </span><span>integer <code>→</code> <span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">int</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (integer)</span><span data-if="dotnet" style="display:none"> (<i>int</i> / </span><span data-if="dotnet" style="display:none">long)</span><span data-if="cpp" style="display:none"> (<i>Hlong</i>)</span><span data-if="c" style="display:none"> (<i>Hlong</i>)</span></span>
</div>
<p class="pardesc">Height of the 1. image.</p>
<p class="pardesc"><span class="parcat">Default:
      </span>512</p>
<p class="pardesc"><span class="parcat">Suggested values:
      </span>128, 256, 512, 1024</p>
<p class="pardesc"><span class="parcat">Restriction:
      </span><code>Height1 &gt; 0</code></p>
</div>
  <div class="par">
<div class="parhead">
<span id="Width2" class="parname"><b><code><span data-if="hdevelop" style="display:inline">Width2</span><span data-if="c" style="display:none">Width2</span><span data-if="cpp" style="display:none">Width2</span><span data-if="com" style="display:none">Width2</span><span data-if="dotnet" style="display:none">width2</span><span data-if="python" style="display:none">width_2</span></code></b> (input_control)  </span><span>integer <code>→</code> <span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">int</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (integer)</span><span data-if="dotnet" style="display:none"> (<i>int</i> / </span><span data-if="dotnet" style="display:none">long)</span><span data-if="cpp" style="display:none"> (<i>Hlong</i>)</span><span data-if="c" style="display:none"> (<i>Hlong</i>)</span></span>
</div>
<p class="pardesc">Width of the 2. image.</p>
<p class="pardesc"><span class="parcat">Default:
      </span>512</p>
<p class="pardesc"><span class="parcat">Suggested values:
      </span>128, 256, 512, 1024</p>
<p class="pardesc"><span class="parcat">Restriction:
      </span><code>Width2 &gt; 0</code></p>
</div>
  <div class="par">
<div class="parhead">
<span id="Height2" class="parname"><b><code><span data-if="hdevelop" style="display:inline">Height2</span><span data-if="c" style="display:none">Height2</span><span data-if="cpp" style="display:none">Height2</span><span data-if="com" style="display:none">Height2</span><span data-if="dotnet" style="display:none">height2</span><span data-if="python" style="display:none">height_2</span></code></b> (input_control)  </span><span>integer <code>→</code> <span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">int</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (integer)</span><span data-if="dotnet" style="display:none"> (<i>int</i> / </span><span data-if="dotnet" style="display:none">long)</span><span data-if="cpp" style="display:none"> (<i>Hlong</i>)</span><span data-if="c" style="display:none"> (<i>Hlong</i>)</span></span>
</div>
<p class="pardesc">Height of the 2. image.</p>
<p class="pardesc"><span class="parcat">Default:
      </span>512</p>
<p class="pardesc"><span class="parcat">Suggested values:
      </span>128, 256, 512, 1024</p>
<p class="pardesc"><span class="parcat">Restriction:
      </span><code>Height2 &gt; 0</code></p>
</div>
  <div class="par">
<div class="parhead">
<span id="SubSampling" class="parname"><b><code><span data-if="hdevelop" style="display:inline">SubSampling</span><span data-if="c" style="display:none">SubSampling</span><span data-if="cpp" style="display:none">SubSampling</span><span data-if="com" style="display:none">SubSampling</span><span data-if="dotnet" style="display:none">subSampling</span><span data-if="python" style="display:none">sub_sampling</span></code></b> (input_control)  </span><span>number <code>→</code> <span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">Union[int, float]</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (integer / </span><span data-if="hdevelop" style="display:inline">real)</span><span data-if="dotnet" style="display:none"> (<i>int</i> / </span><span data-if="dotnet" style="display:none">long / </span><span data-if="dotnet" style="display:none">double)</span><span data-if="cpp" style="display:none"> (<i>Hlong</i> / </span><span data-if="cpp" style="display:none">double)</span><span data-if="c" style="display:none"> (<i>Hlong</i> / </span><span data-if="c" style="display:none">double)</span></span>
</div>
<p class="pardesc">Subsampling factor.</p>
<p class="pardesc"><span class="parcat">Default:
      </span>1</p>
<p class="pardesc"><span class="parcat">List of values:
      </span>1, 2, 3, 1.5</p>
</div>
  <div class="par">
<div class="parhead">
<span id="Mapping" class="parname"><b><code><span data-if="hdevelop" style="display:inline">Mapping</span><span data-if="c" style="display:none">Mapping</span><span data-if="cpp" style="display:none">Mapping</span><span data-if="com" style="display:none">Mapping</span><span data-if="dotnet" style="display:none">mapping</span><span data-if="python" style="display:none">mapping</span></code></b> (input_control)  </span><span>string <code>→</code> <span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">str</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (string)</span><span data-if="dotnet" style="display:none"> (<i>string</i>)</span><span data-if="cpp" style="display:none"> (<i>HString</i>)</span><span data-if="c" style="display:none"> (<i>char*</i>)</span></span>
</div>
<p class="pardesc">Type of mapping.</p>
<p class="pardesc"><span class="parcat">Default:
      </span>
    <span data-if="hdevelop" style="display:inline">'no_map'</span>
    <span data-if="c" style="display:none">"no_map"</span>
    <span data-if="cpp" style="display:none">"no_map"</span>
    <span data-if="com" style="display:none">"no_map"</span>
    <span data-if="dotnet" style="display:none">"no_map"</span>
    <span data-if="python" style="display:none">"no_map"</span>
</p>
<p class="pardesc"><span class="parcat">List of values:
      </span><span data-if="hdevelop" style="display:inline">'bilinear_map'</span><span data-if="c" style="display:none">"bilinear_map"</span><span data-if="cpp" style="display:none">"bilinear_map"</span><span data-if="com" style="display:none">"bilinear_map"</span><span data-if="dotnet" style="display:none">"bilinear_map"</span><span data-if="python" style="display:none">"bilinear_map"</span>, <span data-if="hdevelop" style="display:inline">'nn_map'</span><span data-if="c" style="display:none">"nn_map"</span><span data-if="cpp" style="display:none">"nn_map"</span><span data-if="com" style="display:none">"nn_map"</span><span data-if="dotnet" style="display:none">"nn_map"</span><span data-if="python" style="display:none">"nn_map"</span>, <span data-if="hdevelop" style="display:inline">'no_map'</span><span data-if="c" style="display:none">"no_map"</span><span data-if="cpp" style="display:none">"no_map"</span><span data-if="com" style="display:none">"no_map"</span><span data-if="dotnet" style="display:none">"no_map"</span><span data-if="python" style="display:none">"no_map"</span></p>
</div>
  <div class="par">
<div class="parhead">
<span id="CovFMatRect" class="parname"><b><code><span data-if="hdevelop" style="display:inline">CovFMatRect</span><span data-if="c" style="display:none">CovFMatRect</span><span data-if="cpp" style="display:none">CovFMatRect</span><span data-if="com" style="display:none">CovFMatRect</span><span data-if="dotnet" style="display:none">covFMatRect</span><span data-if="python" style="display:none">cov_fmat_rect</span></code></b> (output_control)  </span><span>number-array <code>→</code> <span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">Sequence[float]</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (real)</span><span data-if="dotnet" style="display:none"> (<i>double</i>)</span><span data-if="cpp" style="display:none"> (<i>double</i>)</span><span data-if="c" style="display:none"> (<i>double</i>)</span></span>
</div>
<p class="pardesc">9x9 covariance matrix of the rectified
fundamental matrix.</p>
</div>
  <div class="par">
<div class="parhead">
<span id="H1" class="parname"><b><code><span data-if="hdevelop" style="display:inline">H1</span><span data-if="c" style="display:none">H1</span><span data-if="cpp" style="display:none">H1</span><span data-if="com" style="display:none">H1</span><span data-if="dotnet" style="display:none">h1</span><span data-if="python" style="display:none">h1</span></code></b> (output_control)  </span><span>hom_mat2d <code>→</code> <span data-if="dotnet" style="display:none"><a href="HHomMat2D.html">HHomMat2D</a>, </span><span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">Sequence[float]</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (real)</span><span data-if="dotnet" style="display:none"> (<i>double</i>)</span><span data-if="cpp" style="display:none"> (<i>double</i>)</span><span data-if="c" style="display:none"> (<i>double</i>)</span></span>
</div>
<p class="pardesc">Projective transformation of the 1. image.</p>
</div>
  <div class="par">
<div class="parhead">
<span id="H2" class="parname"><b><code><span data-if="hdevelop" style="display:inline">H2</span><span data-if="c" style="display:none">H2</span><span data-if="cpp" style="display:none">H2</span><span data-if="com" style="display:none">H2</span><span data-if="dotnet" style="display:none">h2</span><span data-if="python" style="display:none">h2</span></code></b> (output_control)  </span><span>hom_mat2d <code>→</code> <span data-if="dotnet" style="display:none"><a href="HHomMat2D.html">HHomMat2D</a>, </span><span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">Sequence[float]</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (real)</span><span data-if="dotnet" style="display:none"> (<i>double</i>)</span><span data-if="cpp" style="display:none"> (<i>double</i>)</span><span data-if="c" style="display:none"> (<i>double</i>)</span></span>
</div>
<p class="pardesc">Projective transformation of the 2. image.</p>
</div>
<h2 id="sec_example_all">例程 (HDevelop)</h2>
<pre class="example">
* Rectify an image pair using a map.
get_image_size (Image1, Width1, Height1)
get_image_size (Image2, Width2, Height2)
points_harris (Image1, 3, 1, 0.2, 10000, Row1, Col1)
points_harris (Image2, 3, 1, 0.2, 10000, Row2, Col2)
match_fundamental_matrix_ransac (Image1, Image2, Row1, Col1, Row2, Col2, \
                                 'ncc', 21, 0, 200, 20, 50, 0, 0.9, \
                                 'gold_standard', 0.3, 1, FMatrix, \
                                 CovFMat, Error, Points1, Points2)
gen_binocular_proj_rectification (Map1, Map2, FMatrix, [], Width1, \
                                  Height1, Width2, Height2, 1, \
                                  'bilinear_map', CovFMatRect, H1, H2)
map_image (Image1, Map1, Image1Rect)
map_image (Image2, Map2, Image2Rect)

* Rectify an image pair without using a map.
get_image_size (Image1, Width1, Height1)
get_image_size (Image2, Width2, Height2)
points_harris (Image1, 3, 1, 0.2, 10000, Row1, Col1)
points_harris (Image2, 3, 1, 0.2, 10000, Row2, Col2)
match_fundamental_matrix_ransac (Image1, Image2, Row1, Col1, Row2, Col2, \
                                 'ncc', 21, 0, 200, 20, 50, 0, 0.9, \
                                 'gold_standard', 0.3, 1, FMatrix, \
                                 CovFMat, Error, Points1, Points2)
gen_binocular_proj_rectification (Map1, Map2, FMatrix, [], Width1, \
                                  Height1, Width2, Height2, 1, \
                                  'no_map', CovFMatRect, H1, H2)
* Determine the maximum extent of the two rectified images.
projective_trans_point_2d (H1, [0,0,Height1,Height1], \
                           [0,Width1,0,Width1], [1,1,1,1], R1, C1, W1)
R1 := int(floor(R1/W1))
C1 := int(floor(C1/W1))
projective_trans_point_2d (H2, [0,0,Height2,Height2], \
                           [0,Width2,0,Width2], [1,1,1,1], R2, C2, W2)
R2 := int(floor(R2/W2))
C2 := int(floor(C2/W2))
WidthRect := max([C1,C2])
HeightRect := max([R1,R2])
projective_trans_image_size (Image1, Image1Rect, H1, 'bilinear', \
                             WidthRect, HeightRect, 'false')
projective_trans_image_size (Image2, Image2Rect, H2, 'bilinear', \
                             WidthRect, HeightRect, 'false')
</pre>
<h2 id="sec_predecessors">可能的前置算子</h2>
<p>
<code><a href="match_fundamental_matrix_ransac.html"><span data-if="hdevelop" style="display:inline">match_fundamental_matrix_ransac</span><span data-if="c" style="display:none">match_fundamental_matrix_ransac</span><span data-if="cpp" style="display:none">MatchFundamentalMatrixRansac</span><span data-if="com" style="display:none">MatchFundamentalMatrixRansac</span><span data-if="dotnet" style="display:none">MatchFundamentalMatrixRansac</span><span data-if="python" style="display:none">match_fundamental_matrix_ransac</span></a></code>, 
<code><a href="vector_to_fundamental_matrix.html"><span data-if="hdevelop" style="display:inline">vector_to_fundamental_matrix</span><span data-if="c" style="display:none">vector_to_fundamental_matrix</span><span data-if="cpp" style="display:none">VectorToFundamentalMatrix</span><span data-if="com" style="display:none">VectorToFundamentalMatrix</span><span data-if="dotnet" style="display:none">VectorToFundamentalMatrix</span><span data-if="python" style="display:none">vector_to_fundamental_matrix</span></a></code>
</p>
<h2 id="sec_successors">可能的后置算子</h2>
<p>
<code><a href="map_image.html"><span data-if="hdevelop" style="display:inline">map_image</span><span data-if="c" style="display:none">map_image</span><span data-if="cpp" style="display:none">MapImage</span><span data-if="com" style="display:none">MapImage</span><span data-if="dotnet" style="display:none">MapImage</span><span data-if="python" style="display:none">map_image</span></a></code>, 
<code><a href="projective_trans_image.html"><span data-if="hdevelop" style="display:inline">projective_trans_image</span><span data-if="c" style="display:none">projective_trans_image</span><span data-if="cpp" style="display:none">ProjectiveTransImage</span><span data-if="com" style="display:none">ProjectiveTransImage</span><span data-if="dotnet" style="display:none">ProjectiveTransImage</span><span data-if="python" style="display:none">projective_trans_image</span></a></code>, 
<code><a href="binocular_disparity.html"><span data-if="hdevelop" style="display:inline">binocular_disparity</span><span data-if="c" style="display:none">binocular_disparity</span><span data-if="cpp" style="display:none">BinocularDisparity</span><span data-if="com" style="display:none">BinocularDisparity</span><span data-if="dotnet" style="display:none">BinocularDisparity</span><span data-if="python" style="display:none">binocular_disparity</span></a></code>
</p>
<h2 id="sec_alternatives">可替代算子</h2>
<p>
<code><a href="gen_binocular_rectification_map.html"><span data-if="hdevelop" style="display:inline">gen_binocular_rectification_map</span><span data-if="c" style="display:none">gen_binocular_rectification_map</span><span data-if="cpp" style="display:none">GenBinocularRectificationMap</span><span data-if="com" style="display:none">GenBinocularRectificationMap</span><span data-if="dotnet" style="display:none">GenBinocularRectificationMap</span><span data-if="python" style="display:none">gen_binocular_rectification_map</span></a></code>
</p>
<h2 id="sec_references">References</h2>
<p>

J. Gluckmann and S.K. Nayar: “Rectifying transformations that minimize
resampling effects”; IEEE Conference on Computer Vision and Pattern
Recognition (CVPR) 2001, vol I, pages 111-117.
</p>
<h2 id="sec_module">模块</h2>
<p>
3D Metrology</p>
<!--OP_REF_FOOTER_START-->
<hr>
<div class="indexlink">
<a href="index_classes.html"><span data-if="dotnet" style="display:none;">类别</span><span data-if="cpp" style="display:none;">类别</span></a><span data-if="dotnet" style="display:none;"> | </span><span data-if="cpp" style="display:none;"> | </span><a href="index_by_name.html">算子列表</a>
</div>
<div class="footer">
<div class="copyright">HALCON算子参考手册 Copyright © 2015-2023 51Halcon</div>
</div>
</div>
</body>
</html>
